import request from "../request.js";
/**
 * 更新用户信息
 * @param {Object} data
 */
function updateMemberInfo(data) {
	return request({
		url: "/lejuClient/member/updateMemberInfo",
		method: 'POST',
		data,
	});
}

/**
 * 修改密码
 * @param {Object} username
 */
function resetPassword(username) {
	return request({
		url: `/lejuClient/member/resetPassword/${username}`,
		method: 'POST',
	});
}

/**
 * 上传头像
 * @param {Object} data
 */
function uploadAvatar(data) {
	return request({
		url: '/lejuClient/login/uploadAvatar',
		method: "POST",
		data
	});
}

export {
	updateMemberInfo,
	resetPassword,
	uploadAvatar
}
